﻿@model TeamsPortal.Web.Controllers.Models.UploadImageModel

<form id="formUpload" name="formUpload" method="post" enctype="multipart/form-data" action='@Url.HttpRouteUrl("DefaultApi", new { Controller = "Image", Action = "PostAvatar" })'>
    @Html.AntiForgeryToken()
    @Html.HiddenFor(model => model.RedirectUrl)
    @Html.File("File")
    @*@Html.ValidationMessageFor(model => model.File)*@
    <button type="submit">Upload</button>
</form>

<script type="text/javascript">
    $(document).ready(function () {
        var ctx = $('#formUpload');
        $('#File', ctx).change(function (evt) {
            
        });
    });
</script>